<!DOCTYPE HTML>
<html>
<head>
<script src="../../../resources/js-test.js"></script>
</head>
<body>
<p id="description"></p>
<div id="console"></div>
<script>
description('HTMLTextAreaElement.wrap reflects the wrap="" attribute.<br>It is not "limited to only known values", and it is a DOMString attribute which means it just returns the content attributes\'s value directly.');


var textArea = document.createElement('textarea');
document.body.appendChild(textArea);

debug('If wrap attribute is not specified it should be empty String.');
shouldBe('textArea.wrap', "''");

debug('');
debug('Check if it sets warpAttr value hard, should return hard.');
textArea.wrap = "hard";
shouldBe('textArea.wrap', "'hard'");

debug('');
debug('Check if it sets warpAttr value as soft, should return soft.');
textArea.wrap = "soft";
shouldBe('textArea.wrap', "'soft'");

debug('');
debug('Check if warpAttr present but no keyVal specified, should return empty String.');
textArea.wrap = "";
shouldBe('textArea.wrap', "''");

debug('');
debug('Check if it sets warpAttr invaild value, should return foo.');
textArea.wrap = "foo";
shouldBe('textArea.wrap', "'foo'");

debug('');
</script>
</body>
</html>




